home *** CD-ROM | disk | FTP | other *** search
- /*
- File: poll.h
-
- Copyright: © 1993-1997 by Mentat Inc., all rights reserved.
-
- */
-
- /** Copyright (c) 1993 Mentat Inc. this line deleted for release disk
- ** poll.h 4.1, last change 31 Aug 1993 this line deleted for release disk
- **/ /* this line deleted for release disk */
-
- #ifndef __POLL__
- #define __POLL__
- #define _POLL_ /* this line deleted for release disk */
-
- #ifndef __OPENTRANSPORT__
- #include <OpenTransport.h>
- #endif
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=mac68k
- #endif
-
- #define _MIPOLL_
-
- #define NPOLLFILE 20
-
- /* Poll masks */
- #define POLLIN 0x001 /* A non-priority message is available */
- #define POLLPRI 0x002 /* A high priority message is available */
- #define POLLOUT 0x004 /* The stream is writable for non-priority messages */
- #define POLLERR 0x008 /* A error message has arrived */
- #define POLLHUP 0x010 /* A hangup has occurred */
- #define POLLNVAL 0x020 /* This fd is bogus */
- #define POLLRDNORM 0x040 /* A non-priority message is available */
- #define POLLRDBAND 0x080 /* A priority message (band > 0) message is available */
- #define POLLWRNORM 0x100 /* Same as POLLOUT */
- #define POLLWRBAND 0x200 /* A priority band exists and is writable */
- #define POLLMSG 0x400 /* A signal message has reached the front of the queue */
-
- #if SHAPIRO_OUT
- /* array of streams to poll */
- struct pollfd
- {
- int_t fd;
- short events;
- short revents;
- long _ifd; /* Internal "fd" for the benefit of the kernel */
- };
- #endif
-
- /* I_POLL structure for ioctl */
- struct strpoll
- {
- unsigned long nfds;
- struct pollfd* pollfdp;
- int timeout; // shapiro: int_t -> int
- };
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=reset
- #endif
-
- #endif /* _POLL_ */
-